package io.gitee.wminyu.day01;

import java.util.Scanner;

public class runnianpanduan {
    public static void main(String[] args){
        int year;
        do {
            Scanner input = new Scanner (System.in);
            System.out.println("请输入年份，输入-1，停止输入");
             year = input.nextInt();
            if(year % 4 == 0 && year % 100 != 0 || year % 400 == 0){
                System.out.println(year+" 是闰年");
            } else if(year==-1){
                System.out.println(" 输入终止19");
            }
            else {
                System.out.println(year+" 不是闰年");
            }
        }while (year!=-1);

    }
}
